package com.springboot.web;

/**
 * Created by lisu on 2016/11/24.
 */
import com.springboot.Service.UserService;
import com.springboot.domain.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class HelloController {
    @Autowired
    public UserService userService;

    @RequestMapping("/hello")
    public User index() {

        return userService.findByName("AAA");
    }

}